<?php

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 * Description of MemberQuery
 * Class digunakan untuk Query  data dari member Accounts
 * @author Massri
 */
class Application_Model_MemberQuery {
    //put your code here
    private $_db;
    
    function __construct() {
        $registry = Zend_Registry::getInstance();
        $this->_db = $registry->database;
    }
    
    /*
     Query Member Detail 
     */
    public function getMemberDetail($memberId){
        $sql = "select * from v_member where member_id = ?";
        
        $stmt = $this->_db->query($sql,array($memberId));
        
        $data = $stmt->fetchObject();
        
        return $data;
    }
}
